package com.snda.lidejia.hadooptest;

import java.io.IOException;
import org.apache.hadoop.conf.Configured;
import org.apache.hadoop.fs.FileStatus;
import org.apache.hadoop.fs.FileSystem;
import org.apache.hadoop.fs.Path;
import org.apache.hadoop.util.Tool;
import org.apache.hadoop.util.ToolRunner;

/**
 * Hello world!
 *
 */
public class App extends Configured implements Tool {

    public static void main(String[] args) throws Exception {
        int code = ToolRunner.run(new App(), args);
        System.exit(code);
    }

    public int run(String[] strings) throws Exception {
        FileSystem fs = FileSystem.get(getConf());
        Path path = new Path("sort_dn");
        System.out.println(path);
        System.out.println(path.getName());
        System.out.println(path.makeQualified(fs).toUri().getPath());
        return 0;
    }
}
